#include "exception_test.h"

MyException :: MyException(const char* msg){
    this->msg = msg;

}


const char* MyException :: what() const throw()
{
    return this->msg;
}


int test_divide(int i, int j) {
    if(j==0){
        throw MyException("除数为零");
    }

    return i/j;

    
}